 <div class="action-dialog-model-fixed-body">  
	<div class="detaiTab  detaiTab1 detailsBox">
		<div class="openBox">
		<form  action="/massSmsRest/save_sms" id="smsForm" method="post"  class="action-ajax-form action-ajax-form-valid action-ajax-form-confirm" action-ajax-form-confirm-message="确认提交">
		 <p class="p10 ">群发短信(<font color="red">系统定时 五分钟扫描发送一次，建议在操作发送十分钟之后，在列表查询界面查看发送状态</font>)</p>	
		 
		 	   <div class="detaiTab b_t">
					<table class="b_t_e5" width="100%" cellspacing="0" cellpadding="0"
						border="0">
						<tbody>
							<tr>
								<td width="15%" align="right" class="bg">选择文件</td>
								<td><span id="ttt"> <@fileUpload
										url="/massSmsRest/uploadExecl"
										title="导入..." /> </span>
									<div>
										<font color="red"><div id="errorMessage1"></div></font>
									</div></td>
							<tr>
							<tr>
								<td align="right" class="bg"></td>
								<td><a href="/massSmsRest/download">（下载导入模板）</a><font
									class="red ml10"> ${errorMessage}</font></td>
							<tr>
						</tbody>
					</table>
				</div>
	 <div class="detaiTab b_t">
	 	<font color="red"><div id="smsContent"></div></font>
	 	<font color="red"><div id="smsSize"></div></font>
	 </div>
		
		  <div>
				<table border="0" cellpadding="0" cellspacing="0" width="100%">
					<tr>
						<td align="right" class="bg" width="15%">发送类型<span><font color="red">*</font></span></td>
						<td>
							<@select dataSouceType="sendType" id="sendType" name="sendType" value="${vo.sendType}"
							class="tabInp action-valid-field"
							data\-action\-valid\-rule="required;"
							data\-action\-valid\-msg\-required="发送类型不能为空！"/>
							<span class="action-field-error" for="sendType" style="color: red;"></span> 
						</td>
						<td align="right" class="bg" width="15%">定时发送时间<span><font color="red">*</font></span></td>
						<td>
						<@date   type="datetime" style="width:150px;"  name="ScheduleSendDateTime" id="ScheduleSendDateTime"    class="tabInp action-valid-field"
							data\-action\-valid\-rule="" />
						<span class="action-field-error" for="ScheduleSendDateTime" style="color: red;"></span>
						</td>
					</tr>
					<tr>
						<td align="right" class="bg" width="15%">短信内容<span><font color="red">*</font></span></td>
						<td colspan="3" width="85%">
								<textarea style="width:763px; height: 72px;"  class="tabInp action-valid-field" name="content" id="content"
								data-action-valid-rule="required;maxlength:500;"
								data-action-valid-msg-reg="短信内容不能超过500字"
								data-action-valid-msg-required="短信内容不能为空！"></textarea>
								<span class="action-field-error" for="content" style="color: red;"></span>
						</td>
					</tr>
					<tr>
						<td align="right" class="bg" width="15%">短信摘要</td>
						<td colspan="3">
								<textarea style="width:763px; height: 72px;" class="tabInp action-valid-field" name="remark" id="remark"
								data-action-valid-rule="maxlength:50;"
								data-action-valid-msg-reg="短信摘要不能超过50字"></textarea>
								<span class="action-field-error" for="remark" style="color: red;"></span>
						</td>
					</tr>
					<tr>
						<td colspan="4" align="center" >
						<input type="hidden" name ="contactors" id="contactors"/>
						<input type="button" name="smsButton" id="smsButton" class="btn_auto_30 btn_blue mtb20" value="确认提交发送">
						</td>
					</tr>
				</table>
			</div>
			
		</form>
		</div>
	</div>

			<@js>
			
			 	$("select[name='sendType']").click(function(){
			 	 		var sendType = $("#sendType").find("option:selected").val();
						 if(sendType == 'SCHEDULE'){
						   $("#ScheduleSendDateTime").attr('data-action-valid-rule','required');
						 }else{
						   $("#ScheduleSendDateTime").removeAttr('data-action-valid-rule');
						 }
			 	});  
			
			
			
				$("#smsButton").click(function(){
			        var smsContent = $("div[id='smsContent']").text();
					if(smsContent == null||smsContent==''){
						alert("请先上传短信联系人");
					}else{
					     $("#contactors").val(smsContent);
					     $("#smsForm").submit();
					}
				});
			</@js>
			<@jsRender/>

</div>